<template>
  <div>
    <h3>项目中要运用到的知识点</h3>
    <el-row class="empty-line">
        
      <el-col :span="4" v-for="(o, index) in 4" :key="o" :offset="index > 0 ? 2 : 0">
        <el-card :body-style="{ padding: '0px' }">
          <img src="/static/img/car1.png" class="image">
          <div style="padding: 14px;">
            <span>{{index+1}}号教程</span>
            <div class="bottom clearfix">
              <time class="time">{{ currentDate  | parseTime('{y}-{m}-{d} {h}:{i}') }}</time>
              <el-button type="text" class="button">教程链接</el-button>
            </div>
          </div>
        </el-card>
      </el-col>
 
    </el-row>
    <el-row class="empty-line">
      <el-col :span="4" v-for="(o, index) in 4" :key="o" :offset="index > 0 ? 2 : 0">
        <el-card :body-style="{ padding: '0px' }">
          <img src="/static/img/car1.png" class="image">
          <div style="padding: 14px;">
            <span>{{index+5}}号教程</span>
            <div class="bottom clearfix">
              <time class="time">{{ currentDate | parseTime('{y}-{m}-{d} {h}:{i}') }}</time>
              <el-button type="text" class="button">教程链接</el-button>
            </div>
          </div>
        </el-card>
      </el-col>
 
    </el-row>
  </div>
</template>

<style>
  .time {
    font-size: 13px;
    color: #999;
  }
  
  .bottom {
    margin-top: 13px;
    line-height: 12px;
  }

  .button {
    padding: 0;
    float: right;
  }

  .image {
    width: 100%;
    display: block;
  }

  .clearfix:before,
  .clearfix:after {
      display: table;
      content: "";
  }
  
  .clearfix:after {
      clear: both
  }
  .empty-line{
    margin-top:2%;
  }
</style>

<script>
export default {
  data() {
    return {
      currentDate: new Date()
    };
  }
}
</script>
